<template>
    <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"
                   :page-sizes="[10, 50, 200, 400]" :page-size="10" layout="total, sizes, prev, pager, next, jumper"
                   :total="total">
    </el-pagination>
</template>

<script>
export default {
    props: {
        total: {
            type: Number,
            default: 100,
        },
        currentPage: {
            type: Number,
            default: 1,
        }
    },
    methods: {
        handleSizeChange(val) {
            this.$emit('sizeChange', val)
        },
        handleCurrentChange(val) {
            this.$emit('currentChange', val)
        }
    }
}
</script>
